package com.immoc.jdbc.hrapp;

import com.immoc.jdbc.hrapp.command.*;

import java.util.Scanner;

public class HumanResourceApp {
    public static void main(String[] args) {
        System.out.println("1-查询部门员工");
        System.out.println("2-员工入职");
        System.out.println("3-员工调整薪酬");
        System.out.println("4-员工离职");
        System.out.println("5-分页查询");
        Scanner in = new Scanner(System.in);
        Integer cmd = in.nextInt();
        Command command = null;
        switch (cmd) {
            case 1: // 查询员工
                command = new QueryCommand();
                command.execute();
                break;
            case 2: // 查询员工
                command = new InsertCommand();
                command.execute();
                break;
            case 3: // 员工调整薪酬
                command = new UpdateCommand();
                command.execute();
                break;
            case 4: // 员工离职
                command = new DeleteCommand();
                command.execute();
                break;
            case 5: // 员工离职
                command = new Paginaction();
                command.execute();
                break;
        }
    }
}
